//
//  BaseNavController.swift
//  CodingTest
//
//  Created by LYPC on 2021/11/18.
//

import UIKit

class BaseNavController: UINavigationController {
    
    private(set) var logoImg: UIImageView!
    
    override func viewDidLoad() {
        super.viewDidLoad()
        self.isNavigationBarHidden = true
        self.navigationItem.title = ""
    }
    
    override open var preferredStatusBarStyle: UIStatusBarStyle {
        return topViewController?.preferredStatusBarStyle ?? UIStatusBarStyle.default
    }
    
    override func pushViewController(_ viewController: UIViewController, animated: Bool) {
        if self.viewControllers.count > 0 {
            viewController.hidesBottomBarWhenPushed = true
        }
        super.pushViewController(viewController, animated: animated)
    }
}
